package com.customer.feign;

import com.netflix.loadbalancer.IRule;
import com.netflix.loadbalancer.RandomRule;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.cloud.netflix.eureka.EnableEurekaClient;
import org.springframework.cloud.netflix.feign.EnableFeignClients;
import org.springframework.context.annotation.Bean;

@SpringBootApplication
@EnableEurekaClient
@EnableFeignClients(basePackages = {"com.customer.feign"})
public class StudyCustomerFeifnApplication {

    public static void main(String[] args) {
        SpringApplication.run(StudyCustomerFeifnApplication.class, args);
    }

    @Bean
    public IRule getRule(){
        return new RandomRule();
    }
}
